package com.shopAuth.controller;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import com.shopAuth.service.IAppSessionService;

import shopBean.common.bean.RestResult;

@RestController
@RequestMapping("/appSession/")
public class AppSessionContoller {
	@Autowired
	IAppSessionService appSessionService;

	@RequestMapping("createSession.api")
	public RestResult createSession(String tel, String loginIp) {

		return appSessionService.createAppSession(tel, loginIp);
	}

	@RequestMapping("auth.api")
	public RestResult auth(String token) {

		return appSessionService.authSession(token);
	}
}
